home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 January: Mac OS SDK / Dev.CD Jan 97 SDK2.toast / Development Kits (Disc 2) / OpenDoc Development Framework / ODF-Interest Archive / May 96 / Re Can't externalize an FW_C.1 < prev    next >
Encoding:
Internet Message Format  |  1996-12-03  |  1.9 KB  |  [TEXT/ttxt]

  1. Subject:     Re: Can't externalize an FW_CArcShape
  2. Sent:        5/29/96 9:50 PM
  3. Received:    5/30/96 9:27 AM
  4. From:        Jim Lloyd, jim@melongem.com
  5. Reply-To:    ODF Interest, ODF-Interest@CILabs.ORG
  6. To:          OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
  7.  
  8. At 10:28 AM 5/29/96, Walter Holladay wrote:
  9. >I am trying to externalize an FW_CArcShape object, and I'm not having
  10. >much luck.
  11. >When I attempt an FW_WRITE_DYNAMIC_OBJECT, I get the following
  12. >errors:
  13. >
  14. >FWArDyna.cpp @286: GetNameToLabelMap().Find(tempName)
  15. >FWArDyna.cpp @290: item
  16. >FWArDyna.cpp @500: ("No registered archiving functions for class
  17.  
  18. One of our goals with ODF R1 was to faciliate dead-code stripping wherever
  19. possible.  If a part doesn't use a feature, it shouldn't have code for that
  20. feature linked into the part.  This isn't easy to achieve for every
  21. feature, but we spent some time making sure it happened where it could.
  22.  
  23. It turns out that archiving is one area that can defeat dead-stripping.  We
  24. therefore arranged our source files so that all archiving-related code for
  25. most archivable classes are in their own translation units where they can
  26. be easily dead-stripped.  This means that if you don't use archiving for a
  27. class, the archiving-related code won't be linked into your part.  However,
  28. if you do use archiving for a class, you must take explicit action to
  29. prevent the archiving-related code from being dead-stripped!  This is done
  30. with the FW_DO_NOT_DEAD_STRIP macro.  You can call this macro from any
  31. function that you know will definitely not be dead-stripped.  A good place
  32. is your part's Initialize method.
  33.  
  34. By the way, the work we did to faciliate dead-stripping of
  35. archiving-related code reduced the size of ODFNothing by about 40K.  It's a
  36. particularly big win because classes that are not used at all won't be
  37. dead-stripped if their archiving-related functions (in particular, the
  38. Create function) are not dead-stripped.
  39.  
  40. Jim Lloyd
  41.  
  42.